package io;

import java.io.FileWriter;
import java.io.IOException;
import java.io.Writer;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 苏西西
 * Date: 2023-10-15
 * Time: 10:44
 */
public class IOD9 {
    public static void main(String[] args) {
        //使用字符流写一个字符串
       try(Writer writer = new FileWriter("f:/text.txt")){
           writer.write("hello123");
           writer.flush();
       } catch (IOException e) {
           e.printStackTrace();
       }
    }
}
